<?php

session_start();
if (isset($_SESSION['video'])) {
  $video = $_SESSION['video'];
  $video_name = $_SESSION['video_name'];
  $video_ogg = "./video/" . $video . ".ogv";
  $video_webm = "./video/" . $video . ".webm";
  if (!file_exists($video_ogg) && !file_exists($video_webm)) {
    $locStr = 'Location: ' . $conf['base_url'] . 'index.php?error=video_not_exist';
      header($locStr);
  }
} else {
  $locStr = 'Location: ' . $conf['base_url'] . 'index.php?error=no_video_set';
  header($locStr);
}
?>
